package utils;

public class MyException extends Exception {
	public static final int NOT_FOUND = 0, NOT_FOUND_NOT_OPEN = 1, NOT_SUPPORTED = 2, DUPLICATE_WITH_DIFF_TYPE = 3;
	private static final String[] causeMessage = new String[] {
		"not found", "not found or not open", "not supported", "duplicate with unmatching types"
	};
	
	public MyException(String callerType, int cause, String objectName) {
		super(callerType + "(" + objectName + ") " + causeMessage[cause] + ".");
	}
}
